<html>
<script src="Draw.js"></script>
<script src="UI.js"></script>
<script src="Logic.js"></script>
<script src="run.js"></script>
<body>
	<div id="panel">
		<canvas id="canvas"></canvas>
	</div>

</body>

<script>
Logic.start();
window.addEventListener('keydown',doKeyDown,true);
//window.addEventListener('keyup',doKeyUp,true);
window.addEventListener('mousedown',UI.onMouseDown,false);
window.addEventListener('mousemove',UI.onMouseMove,false);
window.addEventListener('mouseup',UI.onMouseUp,false);
function doKeyDown(e){
	Logic.fallAndCheck();
	UI.updateBoard(Logic.board);
	UI.updateScore(Logic.score);
	//Logic.updateActions();
}
</script>

<style>
html, body {
  width:  100%;
  height: 100%;
  margin: 0px;
}

#panel{
	width: 100px;
	height:100px;
	margin: 0px auto;
	border: 0px solid red;
}


</style>

</html>
